// 房屋隐患管理
import type { AppRouteModule } from '/@/router/types';

import { LAYOUT } from '/@/router/constant';
import { t } from '/@/hooks/web/useI18n';

const charts: AppRouteModule = {
  path: '/sstdtj',
  name: 'sstdtj',
  component: LAYOUT,
  redirect: '/sstdtj/targeted',
  meta: {
    orderNo: 202,
    icon: 'ion:bar-chart-outline',
    title: t('routes.demo.sstdtj.root'),
    roles: ['Admin', 'City', 'Area', 'Street', 'Community', 'Investigator'],
    userGroups: ['FireControl'],
  },
  children: [
    {
      path: 'targeted',
      name: 'targeted',
      meta: {
        title: t('routes.demo.sstdtj.targeted'),
        hideChildrenInMenu: true,
        roles: ['Admin', 'City', 'Area', 'Street', 'Community'],
        userGroups: ['Admin', 'FireControl'],
      },
      component: () => import('/@/views/sstdtj/targeted/index.vue'),
      children: [
        {
          path: 'townbaseHourse',
          name: 'townbaseHourse',
          meta: {
            hideMenu: true,
            roles: ['Admin', 'City', 'Area', 'Street', 'Community'],
            userGroups: ['Admin', 'FireControl'],
            title: '双疏散通道统计情况（乡镇）',
          },
          component: () => import('/@/views/sstdtj/targeted/component/townbaseHourse.vue'),
        },
        {
          path: 'villagebaseHourse',
          name: 'villagebaseHourse',
          meta: {
            hideMenu: false,
            roles: ['Admin', 'City', 'Area', 'Street', 'Community'],
            userGroups: ['Admin', 'FireControl'],
            title: '双疏散通道统计情况（村级）',
          },
          component: () => import('/@/views/sstdtj/targeted/component/villagebaseHourse.vue'),
        },
        {
          path: 'hourseDetailLog',
          name: 'hourseDetailLog',
          meta: {
            hideMenu: false,
            roles: ['Admin', 'City', 'Area', 'Street', 'Community'],
            userGroups: ['Admin', 'FireControl'],
            title: '房屋台账',
          },
          component: () => import('/@/views/sstdtj/targeted/hourseDetailLog.vue'),
        },
        {
          path: 'hourseBelowStandard',
          name: 'hourseBelowStandard',
          meta: {
            hideMenu: false,
            roles: ['Admin', 'City', 'Area', 'Street', 'Community'],
            userGroups: ['Admin', 'FireControl'],
            title: '房屋台账',
          },
          component: () => import('/@/views/sstdtj/targeted/hourseBelowStandard.vue'),
        },
      ],
    },
    {
      path: 'personnelwork',
      name: 'personnelwork',
      meta: {
        title: t('routes.demo.sstdtj.personnelwork'),
        hideChildrenInMenu: true,
        roles: ['Admin', 'City', 'Area', 'Street', 'Community'],
        userGroups: ['Admin', 'FireControl'],
      },
      component: () => import('/@/views/sstdtj/personnelwork/index.vue'),
    },
    {
      path: 'housinEarlyWarning',
      name: 'housinEarlyWarning',
      meta: {
        title: t('routes.demo.sstdtj.housinEarlyWarning'),
        hideChildrenInMenu: true,
        roles: ['Admin', 'City', 'Area', 'Street', 'Community'],
        userGroups: ['Admin', 'FireControl'],
      },
      component: () => import('/@/views/sstdtj/housinEarlyWarning/index.vue'),
    },
  ],
};

export default charts;
